package com.enjoyor.soa.traffic.core.efoms.mapper.impl;

import java.util.List;
import java.util.Map;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.enjoyor.soa.traffic.core.efoms.constant.CheckDeviceInfoSqlId;
import com.enjoyor.soa.traffic.core.efoms.constant.CheckRecordInfoSqlId;
import com.enjoyor.soa.traffic.core.efoms.domain.CheckDeviceInfo;
import com.enjoyor.soa.traffic.core.efoms.mapper.ICheckDeviceInfoMapper;
import com.enjoyor.soa.traffic.frame.support.mybatis.mapper.impl.BaseMapper;
import com.enjoyor.soa.traffic.util.pojo.Page;

@Service
@Transactional
public class CheckDeviceInfoMapper extends BaseMapper<CheckDeviceInfo> implements ICheckDeviceInfoMapper{

	@Override
	public List<CheckDeviceInfo> selectCheckDeviceInfoList(Map<String, Object> map) {
		// TODO Auto-generated method stub
		return sqlSessionTemplate.selectList(getSqlName(CheckDeviceInfoSqlId.SQL_SELECT_LIST), map);
	}

	@Override
	public Page selectCheckDeviceInfoPage(Page page) {
		// TODO Auto-generated method stub
		return this.selectPageInfo(getSqlName(CheckDeviceInfoSqlId.SQL_SELECT_ALL), page);
	}

	@Override
	public int getCheckWarnCount(Map<String, Object> map) {
		// TODO Auto-generated method stub
		return sqlSessionTemplate.selectOne(getSqlName(CheckDeviceInfoSqlId.SQL_SELECT_WARN_COUNT), map);
	}

	@Override
	public int getCheckSeriousCount(Map<String, Object> map) {
		// TODO Auto-generated method stub
		return sqlSessionTemplate.selectOne(getSqlName(CheckDeviceInfoSqlId.SQL_SELECT_SERIOUS_COUNT), map);
	}

	@Override
	public int getCheckRepairsCount(Map<String, Object> map) {
		// TODO Auto-generated method stub
		return sqlSessionTemplate.selectOne(getSqlName(CheckDeviceInfoSqlId.SQL_SELECT_REPAIRS_COUNT), map);
	}

	@Override
	public int getCheckNoCheckCount(Map<String, Object> map) {
		// TODO Auto-generated method stub
		return sqlSessionTemplate.selectOne(getSqlName(CheckDeviceInfoSqlId.SQL_SELECT_NOCHECK_COUNT), map);
	}

	@Override
	public int getCheckCheckCount(Map<String, Object> map) {
		// TODO Auto-generated method stub
		return sqlSessionTemplate.selectOne(getSqlName(CheckDeviceInfoSqlId.SQL_SELECT_CHECK_COUNT), map);
	}

	@Override
	public int getNetStatusCount(Map<String, Object> map) {
		// TODO Auto-generated method stub
		return sqlSessionTemplate.selectOne(getSqlName(CheckDeviceInfoSqlId.SQL_GETNET_STATUS_COUNT), map);
	}


	@Override
	public int getHavePicCount(Map<String, Object> map) {
		// TODO Auto-generated method stub
		return sqlSessionTemplate.selectOne(getSqlName(CheckDeviceInfoSqlId.SQL_GETHAVEPIC_COUNT), map);
	}

	@Override
	public int getPicMassCount(Map<String, Object> map) {
		// TODO Auto-generated method stub
		return sqlSessionTemplate.selectOne(getSqlName(CheckDeviceInfoSqlId.SQL_GETPICMASS_COUNT), map);
	}

	@Override
	public int getDateStatusCount(Map<String, Object> map) {
		// TODO Auto-generated method stub
		return sqlSessionTemplate.selectOne(getSqlName(CheckDeviceInfoSqlId.SQL_GETDATEDALEYS_STATUS_COUNT), map);
	}

	@Override
	public int getDaleyDateStatusCount(Map<String, Object> map) {
		// TODO Auto-generated method stub
		return sqlSessionTemplate.selectOne(getSqlName(CheckDeviceInfoSqlId.SQL_GETDATEDALEYS_STATUS_COUNT), map);
	}

}
